export function setItem(key, value) {
  if (typeof value == "object") {
    value = JSON.stringify(value);
  }
	uni.setStorageSync(key, value);
}

export function getItem(key, isJSONObj){
  let value = uni.getStorageSync(key);
  if (isJSONObj && value) {
    value = JSON.parse(value);
  }
  return value;
}

export function removeItem(key) {
  uni.removeStorageSync(key);
}